/* @(#)GSOrderAuthorizeDetailAction.java    
*
* Project: BUS
*
* Modify Information:
* =============================================================================
*   Author       Date       Description
*   ------------ ---------- ---------------------------------------------------
*   Simonyi Peng 2006-3-20    建立
*
* Copyright Notice:
* =============================================================================
*    Copyright (c) 2001-2006 Beijing HiTRUST Technology Co., Ltd. 1808 Room, 
*        Science & Technology Building, No. 9 South Street, Zhong Guan Cun, 
*        Haidian District, Beijing ,100081, China All rights reserved.
*
*    This software is the confidential and proprietary information of
*        Beijing HiTRUST Technology Co., Ltd. ("Confidential Information").
*        You shall not disclose such Confidential Information and shall use it
*        only in accordance with the terms of the license agreement you entered
*        into with HiTRUST.
*
* Warning:
* =============================================================================
* 
*/
package com.hitrust.gs.action;

import system.LoginContext;

import com.hitrust.gs.bean.GSOperatorBean;
import com.hitrust.gs.bean.GSOrderBean;
import com.hitrust.gs.bean.GSOrderDetailBean;
import com.hitrust.gs.business.GSBusOrderProcesser;
import com.hitrust.gs.dao.GSBusOrderDetailDAO;
import com.hitrust.gs.dao.GSOrderDetailDAO;
import com.hitrust.gs.lib.GSBaseConstants;
import com.hitrust.gs.service.GSBaseAction;
import com.hitrust.gs.service.GSBaseForm;
import com.hitrust.gs.util.exception.*;
import com.hitrust.gs.vo.GSBusOrderManufactureVO_;


public class GSOrderAuthorizeDetailAction extends GSBaseAction {
	public String execute(GSBaseForm aForm) throws GSException {
	    GSBusOrderProcesser ordproc = new GSBusOrderProcesser();
	    GSBusOrderDetailDAO dao = new GSBusOrderDetailDAO();
	    
	    String detailId = aForm.getRequest().getParameter("detailId");

        try{
	        GSBusOrderManufactureVO_ detailBean = dao.queryOrderDetailByDetailId(detailId); 
	        GSOrderBean tBean = ordproc.selectOrderByCode(detailBean.orderTempId);
		    aForm.getRequest().setAttribute("orderbean",tBean);
		    
		    aForm.getRequest().setAttribute("detailbean",detailBean);         

            
        }catch(GSException e){
            aForm.getRequest().setAttribute("action", "A150201.do");
            aForm.getRequest().setAttribute("window","true");
            throw e;
        }
        
        return GSBaseConstants.FORWARD_SUCCESS;
        
	}
}
